<html class="ks-webkit537 ks-webkit ks-chrome42 ks-chrome">
	<head>
        <meta charset="gbk">
        <meta name="keywords" content="{$site_seo_keywords}">
        <meta name="description" content="{$site_seo_description}" />
        <title>{$lession['sc_name']}</title>
		<link href="__PUBLIC__/js/artDialog_v6/ui_dialog.css" rel="stylesheet" />
		<link rel="stylesheet" media="screen" href="__PUBLIC__/simplebootx/public/css/play.css" />
		<script src="__PUBLIC__/js/jquery.js"></script>
		<script src="__PUBLIC__/js/artDialog_v6/dialogmin.js"></script>
	</head>
	<body>
		
		<div class="tx-main" style="overflow:hidden;">			
			<div class="tx-banner">
				<div class="tx-banner-left">
					<a href="{:u('course/Course/courseinfo',array('id'=>$lession['cs_id']))}" id="J_goBack">
						<img src="__PUBLIC__/simplebootx/public/images/play_1.png" alt="">
					</a>
				</div>
			   <div class="tx-banner-title" id="J_CourseTitle">{$lession['csname']}</div>
			   <!-- <div class="tx-banner-logo"><a href="#"><img src="__PUBLIC__/simplebootx/public/images/logo.png" alt=""></a></div> -->
			</div>
			<div class="tx-main-inner" id="J_Content">
				<div class="tx-player-wrapper ks-player" style="display: block;  transition: 1s;">
					<div class="hd"></div>
					<div class="bd">						
					<iframe frameborder="0" width="640" height="498" src="{$lession['yun_url']}" allowfullscreen></iframe>
						<div class="container" id="J_Container"  style="transition: 1s;-webkit-transition: 1s;">						
						    <input type="hidden" id="cs_id" value="{$lession['cs_id']}"></input>
							<input type="hidden" id="sc_id" value="{$lession['id']}"></input>
							
							<div class="poster" id="J_PlayOver" style="transition: 1s;-webkit-transition: 1s; display:none;">
								<div class="poster-wrapper-outer">
									<div class="poster-wrapper-inner">
										<div class="icon"></div>
										<div class="detail-wrapper">
											<p>恭喜你，已经学完本节课程，你可以再回顾一下或者继续学习！</p>
										</div>
									</div>
								</div>
							</div>														
						</div>
					</div>
				</div>

				<div class="tx-sidebar-wrapper ks-sidebar" id="J_SideBar"  style="transition: 1s;">
					<div id="J_tab">
						<div class="tab-content" >
							<div class="tab-pannel">
								<div class="tx-info">
									<a class="link" href="">
										<div class="img-wrapper-outer">
											<div class="img-wrapper">
											    <if condition="empty($lession['pic'])">
												   <img class="img" src="__PUBLIC__/images/course.png" alt="{$lession.cs_name}">
												 <else /> 
												   <img class="img" src="{$lession.pic}" alt="{$lession.cs_name}">
												 </if> 
											</div>
										</div>
										<div class="info-wrapper">
											<h3>{$lession['csname']}</h3>
											<span></span>
										</div>
									</a>
								</div>
								<div class="tx-outline ks-outline" data-guid="2" data-initialized="true" style="height: 465px;">
									<div class="outline-inner" id="J_OutlineInner">
										<div class="chapter J_Chapter">
											<h4>章节<span class="num">1</span><span class="name">{$lession['csname']}</span></h4>
											<input type="hidden" id="count" value="{$count}">
											<ul>  
												<volist name="sc_list" id="sub" key="k" >
													<if condition="$cid eq $sub['id']">
													 <a href="{:u('course/Course/study',array('id'=>$sub['id']))}" title="{$sub['sc_name']} " style='text-decoration:none;color:#333;'>
													  <li class="course J_Course head active">
													<else/>
													  <a href="{:u('course/Course/study',array('id'=>$sub['id']))}" title="{$sub['sc_name']}" style='text-decoration:none;color:#333;'>
													  <li class="course J_Course head" id="{$sub['id']}" onmousemove="addhover(this.id)" onmouseout="delhover(this.id)" >
													</if>
														<div class="info">
															<p>课时</p>
															<p class="time">{$sub['sc_time']}</p>
														</div>
														<div class="detail">
															<p>{$sub['sc_name']}</p>
															<div class="resources-wrapper">
																<span class="resources video">
																	<span class="icon"></span>点播
																</span>
															</div>
														</div>
														<if condition="(isstudy($sub['id']) eq 1) or ($cid eq $sub['id'])">
															<span class="progress done"></span>
														<else/>
															<span class="progress"></span>
														</if>
														
													</li>
													</a>
												</volist>		
											</ul> 
										</div>
										<div class="bar"></div>
									</div>
								</div>
							</div>
						</div>
					</div>
					<button class="button button-over bg-red">我学完了</button>
					<div class="action J_Fold unfold">						  
						<span class="tx-learn-iconfont unfold-icon"></span>
						<span class="tx-learn-iconfont fold-icon"></span>
					</div>
				</div>
			</div>
		</div>
	
	</body>
<script type="text/javascript">
   $(".button-over").click(function(){ 
		var sid=document.getElementById("sc_id").value;
		var cid=document.getElementById("cs_id").value;
		var d = dialog({
			title: '正在提交...',
			content: '恭喜你，已经学完本节课程！'
			
		});
		d.width(300)
		d.showModal();
		setTimeout(function () {
			d.close().remove();
		  }, 2000);
		$.ajax({ url:'{:u('Course/Course/studied')}',
			 type:"post", data:{'sc_id':sid,'cs_id':cid}, 
			 dataType:'json', 
			 success:function(data){
			   }
			}
		  );
	}); 
</script>	
</html>